package com.stupidzhe.vbreview.dao;

import com.stupidzhe.vbreview.domain.Student;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface StudentMapper {

    int deleteByPrimaryKey(@Param("userId") Integer userId);

    int insert(Student record);

    int insertSelective(Student record);

    Student selectByPrimaryKey(Integer userId);

    int updateByPrimaryKeySelective(Student record);

    int updateByPrimaryKey(Student record);

    /**
     * 通过classId获取student列表
     * @param classId 班级编号
     * @return student列表
     */
    List<Student> selectByClassId(Integer classId);

    Student selectByAccount(@Param("account") String account);
}